package com.song.module.admin.service;

import com.song.module.admin.entity.ApCookbookIngredient;
import com.song.common.response.PageInfo;
import com.song.module.admin.request.ApCookbookIngredientRequest;

import java.util.List;

/**
 * 菜谱用料接口
 *
 * @author song
 * @date 2024-02-24
 */
public interface IApCookbookIngredientService {
    /**
     * 新增
     *
     * @param param param
     * @return ApCookbookIngredient
     */
    ApCookbookIngredient add(ApCookbookIngredientRequest param);

    /**
     * 删除
     *
     * @param id id
     * @return boolean
     */
    boolean delete(Long id);

    /**
     * 批量删除
     *
     * @param ids ids
     * @return boolean
     */
    boolean deleteBatch(List<Long> ids);

    /**
     * 更新
     *
     * @param param param
     * @return boolean
     */
    boolean update(ApCookbookIngredientRequest param);

    /**
     * 查询单条数据，Specification模式
     *
     * @param id id
     * @return ApCookbookIngredient
     */
    ApCookbookIngredient getById(Long id);

    /**
     * 查询分页数据
     *
     * @param param param
     * @return PageInfo<ApCookbookIngredient>
     */
    PageInfo<ApCookbookIngredient> pageList(ApCookbookIngredientRequest param);


    /**
     * 查询所有数据
     *
     * @return List<ApCookbookIngredient>
     */
    List<ApCookbookIngredient> list(ApCookbookIngredientRequest param);
}
